import request from '@/utils/request'

export function purchaseInfoList(params) {
  return request({
    url: '/ware/purchase/list',
    method: 'get',
    params
  })
}

export function getPurchase(id) {
  return request({
    url: `/ware/purchase/getById/${id}`,
    method: 'get',
  })
}

export function savePurchase(data) {
  return request({
    url: '/ware/purchase/save',
    method: 'post',
    data
  })
}


export function updatePurchase(data) {
  return request({
    url: '/ware/purchase/update',
    method: 'post',
    data
  })
}

export function deletePurchase(ids) {
  return request({
    url: '/ware/purchase/delete',
    method: 'post',
    data: ids
  })
}

